POV-Ray : Newsgroups : povray.binaries.images : office supplies - ink bottle : Re: office supplies - ink bottle Server Time
1 Aug 2024 22:16:02 EDT (-0400)
  Re: office supplies - ink bottle  
From: Chris B
Date: 11 Feb 2008 05:54:23
Message: <47b0295f$1@news.povray.org>
"Jim Charter" <jrc### [at] msncom> wrote in message 
news:47aef6c3$1@news.povray.org...
> Chris B wrote:
>> I've been working on a label generator over the last few days.
>>  ... snip ...
>> By coincidence, yesterday I was thinking about how to do labels for 
>> rounded boxes/superellipsoids though I haven't coded that up yet. I was 
>> thinking of using the width, the depth and the roundness of the corners 
>> to control the shape of a label. The label width would control how far 
>> around the sides of the container the label stretched. Any ideas for 
>> anything that might make it more useful to you?
>>
> It might very well be!  Assuming you are using bi-cubic patches, that was 
> one approach I was also considering.

At the moment I've used CSG, but the SDL is split into two parts and 
modularised to make it easy to extend:

1. There's a label design file, in which you can render the label design 
laid out flat. The design is built up of as many layers as you need. Each 
layer can contain image maps, POV-Ray pigments, object pigments, text blocks 
etc.

2. There's a series of macros, each of which creates a label object of a 
particular shape, based on standardised variables to control the size, then 
wraps the texture around onto its surface. The Width variable defines how 
far around the object the label extends and therefore defines whether it's 
continuous or whether there's a gap round the back.

For a new shape or new texture mapping technique (e.g. bi-cubic patches or 
uv mapping), a new macro can be added. By using standardised variables to 
describe the main attributes it makes it easy for a label designed for one 
object shape to be wrapped around a different shape.

I did a rounded box label shape macro yesterday. Once I've wrapped a texture 
onto it I'll post an image. Do you have a label design for the square 
ink-bottle that I could maybe use as an example - a scan, a sketch or a 
description that I could interpret?

Regards,
Chris B.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.